#ifndef QNalogLISTA_H
#define QNalogLISTA_H

#include "qmybaseformwidget.h"
#include "ui_qNaloglista.h"
#include <QStandardItemModel>
#include <QItemSelection>

class QNalogLista : public QMyBaseFormWidget
{
	Q_OBJECT

public:
    QNalogLista(QWidget *parent = 0);
    ~QNalogLista();
    void lista(const QString& nameSearch);
    void lista_detail(const QString& nameSearch);
	void lista_detail3(const QString& nameSearch, const QString& nameSearch_kol, const QString& m_selectedText2_proizvodID);
    int getSelectedId(){return m_selectedText.toInt();}
    bool getStatusEnableF6(){return 0;}
    virtual void pressEscape();
    virtual void pressReturn();
	QStandardItemModel *model;
    QStandardItemModel *model2;
    QStandardItemModel *model3;
    QStringList geInfo();
	void setRow(int mrow);
	int getRow();

private:
    void deleteDok(int idDok);
    Ui::QNalogListaClass ui;
    QHeaderView *header;
    QHeaderView *header2;
    QHeaderView *header3;
	QString m_selectedText;
	QString m_NalogBroj;
	QString m_Datum;
	QString m_Komintent;
	QString m_VkupenIznosKontoSurovini;
	QString m_VkupenIznosKontoProizvodi;

	QString m_selectedText2;
	QString m_selectedText2_kolicina;
    QString m_selectedText2_proizvodID;
	int m_offset;


    private slots:
        void selectionChanged(QModelIndex modelX, QModelIndex modelY );
		void selectionChangedTable2(QModelIndex modelX, QModelIndex modelY);
        void on_pushButton_clicked();
        void on_pushButton_2_clicked();
        void on_pushButton_4_clicked();
		void prevButtonPressed();
		void nextButtonPressed();
signals:
        void closeW();
        void procF2();
        void procF3();
        void procF6();
		void sFakturiToIzvod(QString& text6, QString& text8, QString& text9, QString& textName, izlFakturaData& mData);
};

#endif // QNalogLISTA_H
